<template>
<view class="content">
  <view v-if="jilu.length">
    <view hover-class="bgitem" v-for="item in jilu" class="item" @click="copy(item)">
      {{item}}
    </view>
  </view>
  <view v-else class="empty">
    <image src="/static/empty.png"></image>
    <text>暂无解析记录</text>
  </view>
</view>

</template>

<script setup>
import {ref} from 'vue'
let jilu = ref([])

let jiluvalue = uni.getStorageSync('jilu');
if(jiluvalue){
  jilu.value=jiluvalue
}

function copy(item){
  uni.setClipboardData({
    data:item,
    success: function () {
      uni.showToast({
        title: '复制成功',
        duration: 2000
      });
    }
  });

}
</script>

<style scoped lang="less">
.content{
  .empty{
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .item{
    background: #fff;

    width: 700rpx;
    margin: 20rpx auto;
    padding: 15rpx;
    box-sizing: border-box;
    border-radius: 10rpx;
  }
  min-height:100vh;
  overflow: auto;
  background-color: #f0f0f0;

}
.bgitem{
  background: #f5f5f5!important;

}
</style>
